/*
 * @Author: your name
 * @Date: 2020-05-14 10:44:11
 * @LastEditTime: 2020-09-15 11:31:31
 * @LastEditors: Please set LastEditors
 * @Description: In User Settings Edit
 * @FilePath: /yigo/src/Utils/StaticData.js
 */


 {/*
            info.typeNumber   
            0: 固定有值的<Text>   
            1: 文本框填写的<TextInput>   
            2: 点击选择的   
            3: TextInput 多行输入的 
            4: datePicker  
            5: 分段选择器 [男,女]
            6: 点击 push下一页选择的
            7: 省,市 两级联动选择器
        */}
import {getTime} from '../Utils/Util'

export const data =  [{title:'客户编码:',type:'Code',other:'',typeNumber:0, must:false, value:'创建成功后自动生成'},
{title:'客户名称:',type:'Name',other:'',typeNumber:1, must:true, value:''},
{title:'客户简称:',type:'ShortName',other:'',typeNumber:1, must:false, value:''},
{title:'所在区域(市):',type:'Province',other:'',typeNumber:7, must:false, value:''},
{title:'所在区域(区)',type:'Area3',other:'',typeNumber:1, must:false, value:''},
{title:'统一社会信用代码:',type:'CreditCode',other:'',typeNumber:1, must:true, value:''},
{title:'客户行业:',type:'CustomerTrade',other:'',typeNumber:2, must:false, value:''},
{title:'是否合作客户:',type:'IsCooperation',other:'',typeNumber:5, must:false, value:''},
{title:'联系人:',type:'Linkman',other:'',typeNumber:1, must:true, value:''},
{title:'联系人职务:',type:'LinkmanPosition',other:'',typeNumber:1, must:false, value:''},
{title:'联系人手机:',type:'LinkmanPhone',other:'',typeNumber:1, must:false, value:'',keyboardType:'numeric'},
{title:'联系人邮箱:',type:'LinkmanEmail',other:'',typeNumber:1, must:false, value:'',keyboardType:'email-address'},
{title:'办公地址:',type:'Address',other:'',typeNumber:1, must:false, value:''},
{title:'办公电话',type:'PhoneNumber',other:'',typeNumber:1, must:false, value:'',keyboardType:'numeric'},
{title:'客户类型:',type:'Type',other:'',typeNumber:2, must:false, value:''},

{title:'企业性质:',type:'EnterpriseProperty',other:'',typeNumber:2, must:false, value:''},
{title:'是否央企:',type:'IsCentral',other:'',typeNumber:5, must:false, value:''},
{title:'归属母集团:',type:'ParentGroup',other:'',typeNumber:6, must:false, value:''},

{title:'是否渠道:',type:'IsChannel',other:'',typeNumber:5, must:false, value:''},
{title:'伙伴名称:',type:'ChannelName',other:'',typeNumber:2, must:false, value:''},
{title:'伙伴社会信用代码:',type:'ChannelCredit',other:'',typeNumber:0, must:false, value:''},
{title:'伙伴联系人:',type:'ChannelLinkman',other:'',typeNumber:0, must:false, value:''},
{title:'伙伴所在区域(省):',type:'ChannelProvince',other:'',typeNumber:0, must:false, value:''},
{title:'伙伴所在区域(市):',type:'ChannelCity',other:'',typeNumber:0, must:false, value:''},
{title:'伙伴所在区域(区):',type:'ChannelArea3',other:'',typeNumber:0, must:false, value:''},

{title:'客户状态:',type:'CustomerStatus',other:'',typeNumber:0, must:false, value:''},
{title:'创建时间:',type:'CreateTime',other:'',typeNumber:0, must:false, value:''},
{title:'创建人:',type:'creator',other:'',typeNumber:0, must:false, value:''},
{title:'创建人部门:',type:'creatorDepartment',other:'',typeNumber:0, must:false, value:''},
{title:'所有人:',type:'allPerson',other:'',typeNumber:0, must:false, value:''},
{title:'所有人部门:',type:'allPersonDepartment',other:'',typeNumber:0, must:false, value:''},

{title:'是否永久有效:',type:'IsPermanent',other:'',typeNumber:0, must:false, value:''},
{title:'客户起始日期:',type:'StartDate',other:'',typeNumber:0, must:false, value:''},
{title:'客户截止日期:',type:'Validity',other:'',typeNumber:0, must:false, value:''},

]


export const customerTrade = [
    {label:"金融",value:1001},
    {label:"电信",value:1002},
    {label:"教育",value:1003},
    {label:"高科技",value:1004},
    {label:"政府",value:1005},
    {label:"制造业",value:1006},
    {label:"服务业",value:1007},
    {label:"能源",value:1008},
    {label:"零售",value:1009},
    {label:"媒体",value:10010},
    {label:"娱乐",value:10011},
    {label:"咨询",value:10012},
    {label:"非盈利事业",value:10013},
    {label:"公共事业",value:10014},
    {label:"其他",value:10015},
];

export const companyType = [
    {label:"央企",value:1001},
    {label:"军工",value:1002},
    {label:"国有企业",value:1003},
    {label:"事业单位",value:1004},
    {label:"民营企业",value:1005},
    {label:"外资企业",value:1006},
    {label:"其他",value:1007}
];

export const customerType = [
    {label:"A",value:'01'},
    {label:"B",value:'02'},
    {label:"C",value:'03'},
    {label:"D",value:'04'},

];



// 创建商机-----------------
export const data01 =  [{title:'商机号:',type:'NO',other:'',typeNumber:0, must:false, value:'创建成功后自动生成'},
{title:'商机日期:',type:'BillDate',other:'',typeNumber:0, must:false, value:getTime(Date.parse(new Date()))},
{title:'商机描述:',type:'BusinessDscription',other:'',typeNumber:1, must:true, value:''},
{title:'客户名称:',type:'CustomerName',other:'',typeNumber:2, must:true, value:''},
{title:'联系人:',type:'Contacts',other:'',typeNumber:0, must:true, value:''},
{title:'商机名称:',type:'businessName',other:'',typeNumber:1, must:true, value:''},
{title:'销售阶段:',type:'SalesStage',other:'',typeNumber:2, must:true, value:''},
{title:'预估成交金额(元):',type:'SingleAmount',other:'',typeNumber:1, must:true, value:'',keyboardType:'numeric'},
{title:'商机来源:',type:'BusSource',other:'',typeNumber:2, must:true, value:''},
{title:'成单概率(%):',type:'SingleProbability',other:'',typeNumber:1, must:true, value:'',keyboardType:'numeric'},
{title:'商机起始日期:',type:'OpportunityStartDate',other:'',typeNumber:0, must:false, value:getTime(Date.parse(new Date()))},
{title:'商机截止日期:',type:'opportunityValidity',other:'',typeNumber:0, must:false, value:getTime(Date.parse(new Date()))},
{title:'预计签约日期:',type:'EstimatedDate',other:'',typeNumber:4, must:true, value:''},
{title:'商机负责人:',type:'opportunityOwners',other:'',typeNumber:2, must:true, value:''},
{title:'商机持续性:',type:'BusinessContinuity',other:'',typeNumber:2, must:true, value:''},
{title:'商机普适性:',type:'BusinessUniversality',other:'',typeNumber:2, must:true, value:''},
{title:'商机类别:',type:'OppType',other:'',typeNumber:2, must:true, value:''},
{title:'创建人:',type:'creator',other:'',typeNumber:0, must:false, value:'-'},
{title:'创建人部门:',type:'creatorDepartment',other:'',typeNumber:0, must:false, value:''},
{title:'商机状态:',type:'OpportunityStatus',other:'',typeNumber:0, must:false, value:''},

]

export const Sale = [
    {label:"得知或收到项目信息，进行评估",value:1001},
    {label:"确定跟进",value:1002},
    {label:"已发标书,准备提交项目建议书",value:1003},
    {label:"已中标或单一来源采购,准备签署LOI,CSA",value:1004}
];

export const BusSource = [
    {label:"自拓商机",value:1},
    {label:"上门商机",value:2},
    {label:"老客户再产出",value:3},
];

export const FindItem = (i,type) => {
    let array = [];
    switch (type) {
        case 'BusSource':
            array = BusSource
            break;
            case 'SaleMain':
            array = companyArray
            break;
            case 'ContractStates':
            array = Status
            break;

            case 'Type':
            array = customerType
            break;

            case 'BusinessType':
            array = BusinessType
            break;
    
        default:
            break;
    }

    for (let index = 0; index < array.length; index++) {
        const element = array[index];
        if (i == element.value) {
            return element.label;
        }
    }
}

export const BusinessContinuity = [
    {label:"一次性",value:1001},
    {label:"一年内/多次性",value:1002},
    {label:"跨年",value:1003},
];

export const BusinessUniversality = [
    {label:"推广",value:1001},
    {label:"复制",value:1002},
    {label:"无",value:1003},
];

export const BusinessType = [
    {label:"ERP",value:1},
    {label:"YIGO平台",value:2},
    {label:"咨询",value:3},
    {label:"实施开发",value:4},
    {label:"运维",value:5},
    {label:"第三方",value:6},
];

//创建明细需要的静态
// 创建商机-----------------
export const data02 =  [{fileNumber:'附件编号:',fileNumberSN:'',fileName:'附件名称',fileNameSN:'',filePath:'附件名称',filePathSN:'',fileDes:'附件说明',fileDesSN:'',fileUpload:'附件上传',fileUploadSN:'附件上传',fileDownload:'附件下载',fileDownloadSN:'附件下载',fileDelete:'附件删除',fileDeleteSN:'附件删除',upLoader:'上传人',upLoaderSN:'',uploadTime:'上传时间',uploadTimeSN:''}]

//添加商机明细
export const data03 = [
    {
            trBefName: {title:'转移前负责人:',type:'trBefName',other:'',typeNumber:2, must:false, value:''},
            trAftName:{title:'转移后负责人:',type:'trAftName',other:'',typeNumber:2, must:false, value:''},
            cusBefName:{title:'转移前客户名称:',type:'cusBefName',other:'',typeNumber:2, must:false, value:''},
            cusAftName:{title:'转移后客户名称:',type:'cusAftName',other:'',typeNumber:2, must:false, value:''},
            TransfeTime:{title:'转移时间:',type:'TransfeTime',other:'',typeNumber:4, must:false, value:''},
            TransfeReason:{title:'转移原因:',type:'TransfeReason',other:'',typeNumber:1, must:false, value:''}
    }];



// 创建合同-----------------
export const data04 =  [{title:'合同编号:',type:'ContractCode',other:'',typeNumber:0, must:false, value:'创建成功后自动生成'},
{title:'商机关联:',type:'BusinessAssociated',other:'',typeNumber:6, must:true, value:''},
{title:'客户名称:',type:'CustomertName',other:'',typeNumber:0, must:true, value:''},
{title:'合同名称:',type:'ContractName',other:'',typeNumber:1, must:true, value:''},
{title:'最终用户:',type:'TheEnduser',other:'',typeNumber:1, must:false, value:''},
{title:'销售主体:',type:'SaleMain',other:'',typeNumber:2, must:false, value:''},
{title:'签约金额(元):',type:'ContractAmount',other:'',typeNumber:1, must:true, value:'',keyboardType:'numeric'},
{title:'签约日期:',type:'SigningDate',other:'',typeNumber:4, must:false, value:''},
{title:'折扣率/利润率(%):',type:'DiscountMargin',other:'',typeNumber:1, must:false, value:'',keyboardType:'numeric'},
{title:'合同状态:',type:'ContractStates',other:'',typeNumber:2, must:false, value:''},
{title:'扩展信息:',type:'ExtInfo',other:'',typeNumber:1, must:false, value:''},
{title:'回款比例(%):',type:'ratio',other:'',typeNumber:1, must:false, value:'',keyboardType:'numeric'}
]

//添加合同明细  -- 收款明细
export const contractInfo00 = [
    {
        CollectionClause: {title:'收款条款:',type:'CollectionClause',other:'',typeNumber:1, must:false, value:''},
        AmountMoney:{title:'收款金额:',type:'AmountMoney',other:'',typeNumber:1, must:false, value:'',keyboardType:'numeric'},
        EstimatedDate:{title:'收款预计日期:',type:'EstimatedDate',other:'',typeNumber:1, must:false, value:''},
        Precondition:{title:'前置条件:',type:'Precondition',other:'',typeNumber:1, must:false, value:''},
    }];

    
//添加合同明细  -- 合同联系人信息
export const contractInfo01 = [
    {
        CompanyName: {title:'单位名称:',type:'CompanyName',other:'',typeNumber:1, must:false, value:''},
        CompanyAddress:{title:'单位地址:',type:'CompanyAddress',other:'',typeNumber:1, must:false, value:''},
        CompanyTel:{title:'单位电话:',type:'CompanyTel',other:'',typeNumber:1, must:false, value:'',keyboardType:'numeric'},
        PersonCharge:{title:'负责人:',type:'PersonCharge',other:'',typeNumber:1, must:false, value:''},
    }];



export const companyArray = [
    {label:"北京博科易购科技有限责任公司",value:0},
    {label:"上海博科易购咨询股份有限责任公司",value:1},
    {label:"深圳博科易购科技有限责任公司",value:2},
];

export const Status = [
    {label:"签约",value:1},
    {label:"执行中",value:2},
    {label:"完毕",value:3},
    {label:"终止",value:4},

];





// 创建销售日志-----------------
export const data05 =  [{title:'单据编号:',type:'NO',other:'',typeNumber:0, must:false, value:'创建成功后自动生成'},
{title:'日志日期:',type:'BillDate',other:'',typeNumber:4, must:true, value:getTime(Date.parse(new Date()))},
{title:'单据状态:',type:'Status',other:'',typeNumber:0, must:false, value:'新建'},
{title:'汇报人:',type:'creator',other:'',typeNumber:0, must:false, value:''},
{title:'汇报人部门:',type:'creatorDepartment',other:'',typeNumber:0, must:false, value:''},
{title:'提交日期:',type:'ReportDate',other:'',typeNumber:0, must:false, value:''},
{title:'本日完成工作:',type:'TodayComplete',other:'',typeNumber:3, must:false, value:''},
{title:'上一日计划执行情况:',type:'UnCompleteWork',other:'',typeNumber:3, must:false, value:''},
{title:'明 日 工 作 计 划:',type:'TomorrowWork',other:'',typeNumber:3, must:false, value:''},
{title:'需  协 调  资 源 :',type:'Coordinate',other:'',typeNumber:3, must:false, value:''},
]
{/*
            info.typeNumber   
            0: 固定有值的<Text>   
            1: 文本框填写的<TextInput>   
            2: 点击选择的   
            3: TextInput 多行输入的 
            4: datePicker  
            5: 分段选择器 [男,女]
            6: 点击 push下一页选择的
            7: 省,市 两级联动选择器
        */}

//添加商机明细
export const data005 = [
    {
        OppDate: {title:'工时日期:',type:'OppDate',other:'',typeNumber:4, must:false, value:''},
        Business:{title:'商机名称:',type:'Business',other:'',typeNumber:6, must:false, value:''},
        Hours:{title:'商机工时:',type:'Hours',other:'',typeNumber:1, must:false, value:'',keyboardType:'numeric'},
    }];


//开票登记
export const data06 =  [{title:'单据编号:',type:'NO',other:'',typeNumber:0, must:false, value:'创建成功后自动生成'},
{title:'单据日期:',type:'BillDate',other:'',typeNumber:0, must:false, value:''},
{title:'补充说明:',type:'Supplement',other:'',typeNumber:1, must:false, value:''},
{title:'客户合同:',type:'ContractManagement',other:'',typeNumber:6, must:true, value:''},
{title:'客户名称:',type:'CustomertName',other:'',typeNumber:0, must:false, value:''},
{title:'合同编号:',type:'ContractCode',other:'',typeNumber:0, must:false, value:''},
{title:'合同名称:',type:'ContractName',other:'',typeNumber:0, must:false, value:''},
{title:'发票类型:',type:'InvoiceType',other:'',typeNumber:2, must:false, value:''},
{title:'发票抬头:',type:'InvoiceTitle',other:'',typeNumber:1, must:false, value:''},
{title:'合同金额:',type:'ContractAmount',other:'',typeNumber:0, must:false, value:'',keyboardType:'numeric'},
{title:'本次开票含税金额:',type:'TaxAmount',other:'',typeNumber:1, must:false, value:'',keyboardType:'numeric'},
{title:'未开票金额:',type:'UninvoicedAmount',other:'',typeNumber:0, must:false, value:'',keyboardType:'numeric'},
{title:'发票内容',type:'InvoiceContent',other:'',typeNumber:1, must:false, value:''},
{title:'税号:',type:'DutyParagraph',other:'',typeNumber:1, must:false, value:''},
{title:'开户银行及账号:',type:'AccountNumber',other:'',typeNumber:1, must:false, value:''},
{title:'地址及电话:',type:'AddAndTel',other:'',typeNumber:1, must:false, value:''},
{title:'发票备注:',type:'InvoiceNote',other:'',typeNumber:1, must:false, value:''},
{title:'邮寄联系人:',type:'MailingContact',other:'',typeNumber:1, must:false, value:''},
{title:'邮寄地址:',type:'MailingAddress',other:'',typeNumber:1, must:false, value:''},
{title:'邮寄联系人电话:',type:'MailingTel',other:'',typeNumber:1, must:false, value:'',keyboardType:'numeric'},
{title:'邮寄联系人邮箱:',type:'MailingEmail',other:'',typeNumber:1, must:false, value:'',keyboardType:'email-address'},
{title:'发票领用人:',type:'InvoiceRequester1',other:'',typeNumber:2, must:false, value:''},
{title:'创建人:',type:'Founder',other:'',typeNumber:0, must:false, value:''},
{title:'创建人部门:',type:'Department',other:'',typeNumber:0, must:false, value:''},
{title:'开票状态:',type:'MakeOutStatus',other:'',typeNumber:2, must:false, value:''},
{title:'邮寄状态:',type:'MailingStatus',other:'',typeNumber:1, must:false, value:''},
{title:'开票拍照:',type:'Photo',other:'',typeNumber:7, must:false, value:''}
]

export const InvoiceType = [
    {label:"专票",value:1001},
    {label:"普票(纸质)",value:1002},
    {label:"普票(电子)",value:1003}
];

export const InvoiceStatus = [
    {label:"申请中",value:1001},
    {label:"已开票",value:1002},
    {label:"已作废",value:1003}
];


// 业绩目标-----------------
export const data07 =  [{title:'单据编号:',type:'NO',other:'',typeNumber:0, must:false, value:''},
{title:'单据日期:',type:'BillDate',other:'',typeNumber:4, must:false, value:''},
{title:'本月业绩目标:',type:'MonthGoal',other:'',typeNumber:1, must:false, value:''},
{title:'回款登记总金额:',type:'MoneyBackNumber',other:'',typeNumber:1, must:false, value:'',keyboardType:'numeric'},
{title:'员工名称:',type:'EmployeeName',other:'',typeNumber:0, must:false, value:''},
{title:'创建人:',type:'Founder',other:'',typeNumber:0, must:false, value:''},
{title:'创建人部门:',type:'Department',other:'',typeNumber:0, must:false, value:''}
]


// 回款登记-----------------
export const data08 =  [{title:'单据编号:',type:'NO',other:'',typeNumber:0, must:false, value:'创建成功后自动生成'},
{title:'单据日期:',type:'BillDate',other:'',typeNumber:4, must:false, value:''},
{title:'合同编号:',type:'ContractCode',other:'',typeNumber:6, must:true, value:''},
{title:'合同名称:',type:'ContractName',other:'',typeNumber:0, must:false, value:''},
{title:'合同金额:',type:'ContractAmount',other:'',typeNumber:0, must:false, value:'',keyboardType:'numeric'},
{title:'客户名称:',type:'CustomertName',other:'',typeNumber:0, must:false, value:''},
{title:'创建人:',type:'Founder',other:'',typeNumber:0, must:false, value:''},
{title:'创建人部门:',type:'Department',other:'',typeNumber:0, must:false, value:''},
{title:'本次回款总金额:',type:'SumRF',other:'',typeNumber:1, must:false, value:'',keyboardType:'numeric'},
{title:'回款比例:',type:'ratio',other:'',typeNumber:1, must:false, value:'',keyboardType:'numeric'},
{title:'本合同回款总金额:',type:'SumRF1',other:'',typeNumber:1, must:false, value:'',keyboardType:'numeric'},

]
// 代办-----------------
export const data09 =  [{title:'工作项标识:',type:'workItemID',other:'',typeNumber:0, must:false, value:'test'},
{title:'工作项名称:',type:'workItemName',other:'',typeNumber:0, must:false, value:''},
{title:'创建时间:',type:'CreatTime',other:'',typeNumber:0, must:false, value:''},
{title:'表单Key:',type:'formkey',other:'',typeNumber:0, must:true, value:''},
{title:'表单标志:',type:'oid',other:'',typeNumber:0, must:false, value:''}
]

//渠道信息
// 创建商机-----------------
export const data10 =  [{title:'代码:',type:'Code',other:'',typeNumber:1, must:false, value:''},
{title:'伙伴名称:',type:'Name',other:'',typeNumber:1, must:true, value:''},
{title:'伙伴社会信用代码:',type:'CreditCode',other:'',typeNumber:1, must:true, value:''},
{title:'伙伴联系人:',type:'Linkman',other:'',typeNumber:1, must:false, value:''},
{title:'伙伴所有省市:',type:'Province',other:'',typeNumber:7, must:false, value:''},
{title:'伙伴所在区域:',type:'Area3',other:'',typeNumber:1, must:false, value:''}
];